import App from './App'

import request from '@/util/api.js'
import {
	getHeight,
	routePath,
	checkStr,
	dateFormat,
	format,
	throttle,
	getCopys,
	uploadImg,
	hideMobile,
	showToast,
	countTime,
	countTime2,
	group,
	uploadMedia
} from '@/common/common.js'
// 引入vuex容器
import store from "./store/index.js"
import '@/util/intercept.js'
//首先在文件下创建一个组件
// import appoint from "components/appoint/appoint.vue"
// //使用component方法
// //语法 第一个参数为组件名称 第二个参数为引入的全局组件
// Vue.component('my-appoint',appoint);

Vue.prototype.$request = request
// Vue.prototype.$request2= myRequest2
Vue.prototype.$getHeight = getHeight
Vue.prototype.$routePath = routePath
Vue.prototype.$checkStr = checkStr
Vue.prototype.$dateFormat = dateFormat
Vue.prototype.$format = format
Vue.prototype.$throttle = throttle
Vue.prototype.$copy = getCopys
Vue.prototype.$uploadImg = uploadImg
Vue.prototype.$hideMobile = hideMobile
Vue.prototype.$showToast = showToast
Vue.prototype.$countTime = countTime
Vue.prototype.$countTime2 = countTime2
Vue.prototype.$group = group
Vue.prototype.$uploadMedia = uploadMedia

// #ifndef VUE3
import Vue from 'vue'
Vue.config.productionTip = false
App.mpType = 'app'

import uView from "uview-ui";
Vue.use(uView);

const app = new Vue({
	store,
	...App
})
app.$mount()
// #endif

// #ifdef VUE3
import {
	createSSRApp
} from 'vue'
export function createApp() {
	const app = createSSRApp(App)
	return {
		app
	}
}
// #endif
